<?php

namespace App\Http\Validate\OpenShop\SiteLocation;

use App\Http\Validate\BaseValidate;

/**
 * [ 提交选址 ] - 校验规则
 *
 * @SubmitFormValidate
 * @package App\Http\Controllers
 * @date 2022/04/26 02:35:56
 * @author huang
 */
class SubmitFormValidate extends BaseValidate
{


    static function registerValidateRules(): void
    {
        // TODO: Implement registerValidateRules() method.
    }

    static function getRules(array $fields = []): array
    {
        return [
            'orderNo'                 => 'required|string',
            'messageFrom'             => 'required',
            'longitude'               => 'required',
            'latitude'                => 'required',
            'siteAddress'             => 'required',
            'cityArea'                => 'required',
            'address'                 => "required",
            'selectTime'              => 'required',
            'currentFormat'           => 'required',
            'operatingStatus'         => 'required',
            'leaseStatus'             => 'required',
            'driveType'               => 'required',
            'siteType'                => 'required',
            'flowLine'                => 'required',
            'orientation'             => 'required',
            'yinYangJie'              => 'required',
            'visualLabel'             => 'required',
            'streetLength'            => 'required',
            'decorationShopType'      => 'required',
            'doorWidth'               => 'required',
            'shopWidth'               => 'required',
            'floorHeight'             => 'required',
            'depth'                   => 'required',
            'area'                    => 'required',
            'electricityConsumption'  => 'required',
            'isCapacityIncrease'      => 'required',
            'capacityIncreaseFee'     => '',
            'exhaustAirVolume'        => 'required',
            'isExhaustReconstruction' => 'required',
            'upperWaterDiameter'      => 'required',
            'lowerWaterDiameter'      => 'required',
            'isReformWater'           => 'required',
            'airConditionerCType'     => 'required',
            'isFireControl'           => 'required',
            'adSpaceNumber'           => '',
            'rentType'                => 'required',
            'fixedRent'               => '',
            'remind'                  => 'required',
            'rentPaymentCycle'        => 'required',
            'deposit'                 => '',
            'leaseTerm'               => '',
            'rentFreePeriod'          => '',
            'caseRegisterType'        => 'required',
            'waterFee'                => '',
            'electricityFee'          => '',
            'propertyFee'             => '',
            'mobilizationMobile'      => '',
            'mobilizationFee'         => '',
            'mobilizationFeeDesc'     => '',
            'bond'                    => '',
            'manageFee'               => '',
            'sponsorshipFee'          => '',
            'promotionFee'            => '',
            'otherFee'                => '',
            'otherFeeDesc'            => '',
            'leaseMobile'             => 'required',
            'leaseName'               => 'required',
            'leaseWeChat'             => '',
            'businessStrategy'        => 'required',
            'restrictedSales'         => '',
            'siteAdvantage'           => 'required',
            'siteInferiority'         => 'required',
            'productAnalysis'         => 'required|array',
            'customerAnalysis'        => 'required|array',
            'leftPhoto'               => 'required|array',
            'rightPhoto'              => 'required|array',
            'frontPhoto'              => 'required|array',
            'innerPhoto'              => 'required|array',
            'panoramaPhoto'           => 'required|array',
            'shopVideo'               => 'required|array',
            'heatMap'                 => 'required|array',
            'lineMarking'             => 'required|array',
            'shopType'                => '',
            'siteSelection'           => '',
        ];
    }

    public static array $attributes = [
        'orderNo'                 => '订单编号',
        'messageFrom'             => '门店信息来源',
        'longitude'               => '门店经度',
        'latitude'                => '门店纬度',
        'siteAddress'             => '经纬度地址',
        'cityArea'                => '门店城市',
        'address'                 => "门店地址",
        'selectTime'              => '选址时间',
        'currentFormat'           => '当前业态',
        'operatingStatus'         => '当前经营状态',
        'leaseStatus'             => '当前租赁状态',
        'driveType'               => '客流驱动类型',
        'siteType'                => '店址类型',
        'flowLine'                => '人流动线',
        'orientation'             => '朝向',
        'yinYangJie'              => '阴阳街',
        'visualLabel'             => '可视化标签',
        'streetLength'            => '商业街长度',
        'decorationShopType'      => '装修店型',
        'doorWidth'               => '门宽',
        'shopWidth'               => '店宽',
        'floorHeight'             => '层高',
        'depth'                   => '进深',
        'area'                    => '面积',
        'electricityConsumption'  => '用电量',
        'isCapacityIncrease'      => '是否电量增容',
        'capacityIncreaseFee'     => '电量增容费用',
        'exhaustAirVolume'        => '排风量',
        'isExhaustReconstruction' => '排风改造',
        'upperWaterDiameter'      => '上水管径',
        'lowerWaterDiameter'      => '下水管径',
        'isReformWater'           => '是否支持上下水管径改造',
        'airConditionerCType'     => '空调类型',
        'isFireControl'           => '是否消防',
        'adSpaceNumber'           => '广告位数量',
        'rentType'                => '记租类型',
        'fixedRent'               => '固定租金',
        'remind'                  => '提点百分比',
        'rentPaymentCycle'        => '付款周期',
        'deposit'                 => '押金',
        'leaseTerm'               => '租期',
        'rentFreePeriod'          => '免租期',
        'caseRegisterType'        => '收银机类型',
        'waterFee'                => '水费',
        'electricityFee'          => '电费',
        'propertyFee'             => '物业费',
        'mobilizationMobile'      => '进场联系人',
        'mobilizationFee'         => '进场费',
        'mobilizationFeeDesc'     => '进场费说明',
        'bond'                    => '保证金',
        'manageFee'               => '管理费',
        'sponsorshipFee'          => '赞助费',
        'promotionFee'            => '推广费',
        'otherFee'                => '其它费用',
        'otherFeeDesc'            => '其它费用说明',
        'leaseMobile'             => '店面出租联系方式',
        'leaseName'               => '店面出租联系人',
        'leaseWeChat'             => '店面出租微信',
        'businessStrategy'        => '经营策略',
        'restrictedSales'         => '产品限制销售范围',
        'siteAdvantage'           => '店址优势',
        'siteInferiority'         => '店址劣势',
        "heatMap"                 => '百度热力图',
        'leftPhoto'               => '左视图',
        'rightPhoto'              => '右视图',
        'frontPhoto'              => '正视图',
        'innerPhoto'              => '店内图',
        'panoramaPhoto'           => '远景图',
        'shopVideo'               => '视频',
        'lineMarking'             => '动线说明',
        'infoPhoto'               => '营业资料图片',
        'infoPdf'                 => '营业资料pdf',
        'productAnalysis'         => '竞品分析',
        'customerAnalysis'        => '客群分析',
        'shopType'                => '店型',
        'siteSelection'           => '选址场景',
    ];

    public static function submitBaseValidate(array $requestParams): array
    {
        return self::baseValidate(
            $requestParams,
            array_keys(self::getRules()),
            null,
            null,
            self::getValidateMsg()
        );
    }


}
